<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      let stus = [
        { name: "阿花", score: 40, gender: "女孩" },
        { name: "阿兰", score: 60, gender: "女孩" },
        { name: "阿冰", score: 80, gender: "女孩" },
        { name: "阿美", score: 100, gender: "女孩" },
      ];
      let max = stus[0].score;
      for (let i = 0; i < stus.length; i++) {
        if (max < stus[i].score) {
          max = stus[i].score;
        }
      }
      for (let j = 0; j < stus.length; j++) {
        if (max === stus[j].score) {
          console.log(stus[j].name);
        }
      }
    </script>
  </body>
</html>
